//WMPPlusCore.h
#include "..\WMP\Common.h"
#include "WMPPlusHook.h"

#pragma once

enum WMPPLUS_PROPERTY {
	/*WMPPlusHookData*/WMPPLUS_PROPERTY_HOOK_MENU,
	/*WMPPlusHookData*/WMPPLUS_PROPERTY_HOOK_WMPCLOSE,
	/*WMPPlug*/WMPPLUS_PROPERTY_WMPVERSION,
	/*WMPPlusPublic*/WMPPLUS_PROPERTY_MEDIAFOLDER,
	/*WMPPlusPublic*/WMPPLUS_PROPERTY_MEDIAFOLDERLIST,
	/*WMPPlus*/WMPPLUS_PROPERTY_LIBMENU,
	/*WMPUIAddons*/WMPPLUS_PROPERTY_ADDONS_TAGEDITOR,
	/*WMPUIAddons*/WMPPLUS_PROPERTY_ADDONS_CONTEXTMENU,
	/*WMPUIAddons*/WMPPLUS_PROPERTY_ADDONS_TAGEDITORLABEL,
	/*WMPUIAddons*/WMPPLUS_PROPERTY_ADDONS_WMPTITLE,
	/*WMPUIAddons*/WMPPLUS_PROPERTY_ADDONS_TITLE,
	WMPPLUS_PROPERTY_SETTINGS_MSNENABLE,
	WMPPLUS_PROPERTY_SETTINGS_MSNHIDEONPAUSE,
	WMPPLUS_PROPERTY_SETTINGS_MSNSHOWVIDEO,
	WMPPLUS_PROPERTY_SETTINGS_DISABLEGROUPHEADERS,
	WMPPLUS_PROPERTY_SETTINGS_FINDASYOUTYPE,
	WMPPLUS_PROPERTY_SETTINGS_INCLUDESETINTRACKNUMBERS,
	WMPPLUS_PROPERTY_SETTINGS_SHOWATEINPLAYLISTVIEW,
	WMPPLUS_PROPERTY_SETTINGS_CURRENTMEDIAINTITLE,
	WMPPLUS_PROPERTY_SETTINGS_SHOWFILEMENUITEMLIBRARYPANE,
	WMPPLUS_PROPERTY_SETTINGS_SHOWFILEMENUITEMLISTPANE,
	WMPPLUS_PROPERTY_SETTINGS_SHOWTAGEDITORPLUSLIBRARYPANE,
	WMPPLUS_PROPERTY_SETTINGS_SHOWTAGEDITORPLUSLISTPANE,
	WMPPLUS_PROPERTY_SETTINGS_SHOWTAGEDITORPLUSFOROTHERTYPES,
	WMPPLUS_PROPERTY_SETTINGS_RESTORELASTPLAYLIST,
	WMPPLUS_PROPERTY_SETTINGS_RESTORELASTMEDIA,
	WMPPLUS_PROPERTY_SETTINGS_RESTORELASTPLAYSTATE,
	WMPPLUS_PROPERTY_SETTINGS_RESTORELASTPOSITION,
	WMPPLUS_PROPERTY_SETTINGS_RESTOREPAUSED,
	WMPPLUS_PROPERTY_SETTINGS_PARTYSHUFFLECONFIGURED,
	WMPPLUS_PROPERTY_SETTINGS_PARTYSHUFFLEPENDINGSOURCECHANGE,
	WMPPLUS_PROPERTY_SETTINGS_SPACEBARPLAYPAUSE,
	WMPPLUS_PROPERTY_SETTINGS_MSNATFSTRING,
	WMPPLUS_PROPERTY_SETTINGS_TASKBARATFSTRING,
	WMPPLUS_PROPERTY_SETTINGS_PARTYSHUFFLEPLAYLISTNAME,
	WMPPLUS_PROPERTY_SETTINGS_PARTYSHUFFLEPLAYLISTFILENAME,
	WMPPLUS_PROPERTY_SETTINGS_PARTYSHUFFLESOURCEPLAYLISTNAME,
	WMPPLUS_PROPERTY_SETTINGS_PARTYSHUFFLESOURCEPLAYLISTFILENAME,
	WMPPLUS_PROPERTY_SETTINGS_LASTUNSUPPORTEDVERSION,
	WMPPLUS_PROPERTY_SETTINGS_TAGEDITORWIDTH,
	WMPPLUS_PROPERTY_SETTINGS_TAGEDITORHEIGHT,
	WMPPLUS_PROPERTY_SETTINGS_TAGEDITORPAGE,
	WMPPLUS_PROPERTY_SETTINGS_MESSAGEBOXWIDTH,
	WMPPLUS_PROPERTY_SETTINGS_MESSAGEBOXHEIGHT,
	WMPPLUS_PROPERTY_SETTINGS_RESTOREPOSITIONREWIND,
	WMPPLUS_PROPERTY_SETTINGS_PARTYSHUFFLEPLAYEDSONGS,
	WMPPLUS_PROPERTY_SETTINGS_PARTYSHUFFLEUPCOMINGSONGS,
	WMPPLUS_PROPERTY_SETTINGS_PARTYSHUFFLEPLAYLISTINDEX,
	WMPPLUS_PROPERTY_SETTINGS_INCLUDESETMAXITEMCOUNT,
	WMPPLUS_PROPERTY_SETTINGS_PLAYNEXTMAXITEMCOUNT,
	WMPPLUS_PROPERTY_COUNT
};

class WMPPlusHookData;

class WMPPlusCore {
	INT_PTR prop[(int)WMPPLUS_PROPERTY_COUNT];
public:
	WMPPlusHookData* Hook;

	WMPPlusCore();
	~WMPPlusCore();
	inline LPCTSTR getStrProp(WMPPLUS_PROPERTY index) {
		return (LPCTSTR)prop[(int)index];
	}
	void setStrProp(WMPPLUS_PROPERTY index, LPCTSTR value);
	inline void* getPtrProp(WMPPLUS_PROPERTY index) {
		return (void*)prop[(int)index];
	}
	inline void setPtrProp(WMPPLUS_PROPERTY index, void* value) {
		prop[(int)index] = (INT_PTR)value;
	}
	inline int getIntProp(WMPPLUS_PROPERTY index) {
		return (int)prop[(int)index];
	}
	inline void setIntProp(WMPPLUS_PROPERTY index, int value) {
		prop[(int)index] = (INT_PTR)value;
	}
	inline bool getBoolProp(WMPPLUS_PROPERTY index) {
		return !!prop[(int)index];
	}
	inline void setBoolProp(WMPPLUS_PROPERTY index, bool value) {
		prop[(int)index] = (INT_PTR)value;
	}
};
extern WMPPlusCore* Core;

void* WINAPI WMPPlusCoreGetProp(WMPPLUS_PROPERTY index);
void WINAPI WMPPlusCoreSetProp(WMPPLUS_PROPERTY index, void* value);
